package com.sgb.kjwl.view.ui.adapter.self.publish;

import android.content.Context;
import android.widget.TextView;

import com.sgb.kjwl.BR;
import com.sgb.kjwl.R;
import com.sgb.kjwl.model.entity.user.CategoryEntity;
import com.swgk.core.recyclerview.adapter.BaseRecycleAdapter;
import com.swgk.core.recyclerview.adapter.ItemViewHolder;

import java.util.List;

public class PackersTypeChoiceAdapter extends BaseRecycleAdapter<CategoryEntity> {
    private TextView type_tv;

    public PackersTypeChoiceAdapter(Context context, List<CategoryEntity> datas) {
        super(context, R.layout.item_packers_type, datas);
    }

    @Override
    public void convert(ItemViewHolder holder, final CategoryEntity entity) {
        holder.setBinding(BR.viewModel, entity);
        type_tv = holder.itemView.findViewById(R.id.type_tv);
        type_tv.setText(entity.getName());
    }

}
